cmake_minimum_required(VERSION 2.6)

project(hello)

message(STATUS "--> Hello from CMake")

if (WIN32)
	message("--> Running on windows")
else()
    message("--> Assuming running on Linux")
endif()

message(STATUS "Running from ${CMAKE_CURRENT_SOURCE_DIR}")

if (NOT EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/hello.cpp")
	message(FATAL_ERROR "File hello.cpp not found!")
endif()

option(ENABLE_DEBUG "Enable debugging messages"
         FALSE)

if (ENABLE_DEBUG)
	message(STATUS "Debugging messages are enabled")
endif()
		 
	 
add_executable(hello hello.cpp)

install(TARGETS hello RUNTIME DESTINATION ${CMAKE_CURRENT_SOURCE_DIR}/../bin)

				

